home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1996 February / EnigmA AMIGA RUN 04 (1996)(G.R. Edizioni)(IT)[!][issue 1996-02][Skylink CD III].iso / earcd / util4 / anegato.lha / A.negato1.2 / Source / AAsk.code next >
Text File  |  1992-09-02  |  1KB  |  51 lines

  1. WBStartup : WbToScreen 0
  2. SetErr:DisplayBeep_(0):End SetErr
  3.  
  4. StringGadget 0,10,26,0,0,50,120
  5. StringGadget 0,160,26,0,1,50,120
  6. Window 0,35,15,300,50,$1000|$8,"Inserisci Password, Grazie!",1,2,0
  7.  
  8. ActivateString 0,0 ;attiva il gadget stringa "NOME"
  9.  
  10. Repeat
  11.   VWait
  12.   WLocate 29,5:Print"NOME UTENTE"
  13.   WLocate 190,5:Print"PASSWORD"
  14.   w.l=WaitEvent
  15.   If w=$200
  16.     c.s=StringText$(0,0)+StringText$(0,1)
  17.     c=LCase$(c) ;c$=NOME+PASSWORD in minuscolo
  18.     Goto via
  19.   End If
  20. Forever
  21.  
  22. via
  23. If Exists("S:ANeg")
  24. If OpenFile(0,"S:ANeg")
  25.   MaxLen d$=40
  26.   MaxLen e$=40
  27.   MaxLen f$=40
  28.   Fields 0,d$,e$,f$
  29.   Get 0,0
  30.   If (c<>d$ AND c<>e$ AND c<>f$) OR c="" ;se c$ non coincide con nessuna
  31.                                ;stringa registrata: beh, spegni il computer!
  32.     Repeat
  33.       VWait
  34.       DisplayBeep_(0)
  35.     Forever
  36.   End If
  37. CloseFile 0
  38. Else
  39.   DisplayBeep_(0)
  40. End If
  41.  
  42. If OpenFile(0,"S:Ultimouso")
  43.   FileOutput 0
  44.   Print " Codice Ultimo Utente: ",c,"                                  "
  45.   CloseFile 0
  46. Else
  47.   DisplayBeep_(0)
  48. End If
  49. End If
  50. End
  51.